package mafiagame;

public class SleepAction extends Action
{
	Game myGame;
	Player myPlayer;
	public SleepAction(Game g, Player p)
	{
		myGame = g;
		myPlayer = p;
	}
	
	@Override
	public String getDescription()
	{
		return "A majority of players must choose to sleep in order for a day to turn into night.";
	}

	@Override
	public String getCommand()
	{
		return "!sleep";
	}

	@Override
	public boolean Execute(String message)
	{
		myGame.playerSleeps(myPlayer);
		return true;
	}

	@Override
	public boolean isPublic()
	{
		return true;
	}

	@Override
	public void Resolve()
	{
		// This action should never actually be resolved.		
	}

}
